<?php

/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
include("includes/functions.php");

$propertyTypes=getPropertyTypes();
$cities=getCities();
?>

<div class="boxHeader">Emlak Kayit</div>
<div id="dsad" style="padding-left:20px;">
    <form action="addPropertyStep2.php" method="POST">
        <input type="hidden" name="MAX_FILE_SIZE" value="100000" />
        <input type="hidden" id="lat" name="lat"  />
        <input type="hidden" id="lng" name="lng"  />
        <table border="0">

            <tr>
                <td>
                    <table width="300px" border="0">
                        <tbody>
                            <tr>
                                <td><strong>Durumu</strong></td>
                                <td>Kiralık <input  type="radio" id="offerType" name="offerType" value="1" /> Satilik <input type="radio" name="offerType" value="2" /></td>
                            </tr>

                            <tr>
                                <td><strong>Türü</strong></td>
                                <td>
                                    <select onchange="MakeRequest('parts/dataInput/propertyExtras.php?type='+this.value,'extras');" id="propertyType">
                                        <option value="0"> Seçiniz </option>
                                        <?php foreach($propertyTypes as $type){ echo "<option value=\"".$type['id']."\">".$type['name']."</option>";  }?>
                                </select></td>
                            </tr>
                            <tr>
                                <td> <strong>Şehir</strong> </td>
                                <td><select id="city">
                                        <option value="0"> Seçiniz </option>
                                        <?php foreach($cities as $city){ echo "<option value=\"".$city['id']."\">".$city['name']."</option>";  }?>
                                </select></td>
                            </tr>
                            <tr>
                                <td> <strong>Fiyat</strong> </td>
                                <td><input onblur="iblur('price');" onfocus="ifocus('price');" type="text" id="price" value="" size="5" /> YTL</td>
                            </tr>
                            <tr>
                                <td> <strong>Alan</strong> </td>
                                <td><input onblur="iblur('area');" onfocus="ifocus('area');" type="text" id="area" value="" size="5" /> m2</td>
                            </tr>
                            <tr>
                                <td valign="top"> <strong>Detaylar</strong> </td>
                                <td><textarea onblur="iblur('details');" onfocus="ifocus('details');" id="details" rows="7" cols="30"></textarea></td>
                            </tr>
                            <tr>
                                <td> <strong>Fotoğraf</strong> </td>
                                <td><input type="file" name="photo1" value="" width="25" /></td>
                            </tr>
                            <tr>
                                <td colspan="2" align="center"><br/><br/><br/><input onclick="addProperty();" type="button" value="Kaydet" /></td>

                            </tr>
                        </tbody>
                    </table>

                </td>
                <td valign="top"> <div id="extras"></div></td>
            </tr>

        </table>


    </form>
</div>
